﻿/* 
 *     This file is part of Kuka-KR3 Rubik's Cube Solver.
 *
 *    Kuka-KR3 Rubik's Cube Solver is free software: you can redistribute it and/or modify
 *    it under the terms of the GNU General Public License as published by
 *    the Free Software Foundation, either version 3 of the License, or
 *    (at your option) any later version.
 *
 *    Foobar is distributed in the hope that it will be useful,
 *    but WITHOUT ANY WARRANTY; without even the implied warranty of
 *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *    GNU General Public License for more details .
 *
 *    You should have received a copy of the GNU General Public License
 *    along with Kuka-KR3 Rubik's Cube Solver.  If not, see <http://www.gnu.org/licenses/>.
 *    
 * 
 */


namespace CubeCalculations
{

   public delegate void StatusChangedHandler(float Progress, float Fitness);
      



   public enum SolveMethod
   {
      Evolutionary,
      Distance,
   }

   public enum CubeRotation : uint
   {
      Right = 1,
      Left = 2,
   }
   public enum KR3Moves : uint
   {
      MoveLeft = 0,
      MoveRight = 1,
      Move180 = 2,
      FlipToBack,
      FlipToFront,
      RotateLeft,
      RotateRight,
      Rotate180,
   }

   public enum CubeSides : uint
   {
      Top = 0,
      Left = 1,
      Front = 2,
      Right = 3,
      Back = 4,
      Bottom = 5
   }
   //public enum CubeSides : uint
   //{
   //   Front = 0,
   //   Right = 1,
   //   Back = 2,
   //   Left = 3,
   //   Top = 4,
   //   Bottom = 5
   //}


   public enum CubeMoves : uint
   {
      //     xxxx     - Seiten-Identifier
      //         0001 - Rechtsrum drehen (obere Seite - wenn untere Seite fest steht)
      //         0002 - Linksrum drehen  (obere Seite - wenn untere Seite fest steht)

      UL = CubeRotation.Right | (CubeSides.Top << 16),  //Up Left
      UR = CubeRotation.Left | CubeSides.Top << 16,  //Up Right       --- Wenn man frontal auf den Würfel schaut, wird die ebene nach Rechts gedreht.
      //                                     Sofern man den Würfel von oben betrachtet, dreht man aber Linksrum (Counterclockwise)
      DL = CubeRotation.Left | CubeSides.Bottom << 16,  //Down Left
      DR = CubeRotation.Right | CubeSides.Bottom << 16,  //Down Right
      LU = CubeRotation.Left | CubeSides.Left << 16,  //Left Up
      LD = CubeRotation.Right | CubeSides.Left << 16,  //Left Down
      RU = CubeRotation.Right | CubeSides.Right << 16,  //Right Up
      RD = CubeRotation.Left | CubeSides.Right << 16,  //Right Down
      FC = CubeRotation.Right | CubeSides.Front << 16,  //Front Clockwise
      FA = CubeRotation.Left | CubeSides.Front << 16,  //Front Counterclockwise
      BC = CubeRotation.Left | CubeSides.Back << 16,  //Back Clockwise         --- Auch hier gilt: man guckt frontal auf den Würfel (Vorderseite) 
      BA = CubeRotation.Right | CubeSides.Back << 16,  //Back Counterclockwise
   }
   public enum CubeSideRotation : int
   {
      None = 0,
      Clockwise90 = 1,
      Clockwise180 = 2,
      Clockwise270 = 3,
   }

   public enum Positions : int
   {
      StartPositionUp = 0,              //Über dem würfel, ausganggsposition
      StartPositionDown = 1,            //"ausgangspos (im Würfel)"
      StartPositionDownSwingLeft,            //"ausgangspos (im Würfel)"
      StartPositionDownSwingRight,            //"ausgangspos (im Würfel)"
      FrontClockwiseDown,           //"Clockwise(Front)"
      FrontClockwiseDownSwing,
      FrontClockwiseUp,                //"ObenClockwise"
      FrontCounterClockwiseDown ,      //"CounterClockwise",
      FrontCounterClockwiseUp,         //"ObenCounterClockwise"
      FlipTopUp,                          //"ausgangspos OBEN zum Kippen(im Würfel)"
      FlipTopDown ,                        //"ausgangspos zum Kippen(im Würfel)",
      FlipTopUpToDown,                        //"zwischenposition beim kippeen zum sanften "einparken"
      FlipTopP1,                    //"Kippen, Zwischenstation1",
      FlipTopP2,                    //"Kippen, Zwischenstation2"
      FlipFrontUp ,                    //"Kippen, Zwischenstation3",
      FlipFrontUpToDown,                    //"Kippen, Zwischenstation3",
      FlipFrontDown,                  //"Kippen, Absetzen"
      CameraFront,                  //"
      CameraBack,                  //"
   }

}
  
